package com.biqee.util;

import java.lang.reflect.InvocationTargetException;

import org.apache.commons.beanutils.BeanUtils;
import org.apache.log4j.Logger;

import com.biqee.model.JuHuaSuanItemOfPage;
import com.biqee.model.db.TbJuItem;

public class TbJuItemUtil {
	private static final Logger logger = Logger.getLogger(TbJuItemUtil.class);
	
	public static TbJuItem createTbJuItem(JuHuaSuanItemOfPage item) {
		TbJuItem itemInDB = new TbJuItem();
		
		try {
			BeanUtils.copyProperties(itemInDB, item);
			return itemInDB;
		} catch (IllegalAccessException e) {
			logger.error("", e);
		} catch (InvocationTargetException e) {
			logger.error("", e);
		}

		return null;
	}
	
}
